package com.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.common.mybatis.Page;
import com.entity.Information;
import com.repository.InformationDao;
import com.service.base.BaseServiceImp;

@Service("informationService")
public class informationServiceImp extends BaseServiceImp<Information> implements informationService{
	@Autowired
	private InformationDao ndDao;
	
	@Override
	@Transactional
	public boolean insertprice(Information o) {
		Information uir=new Information();
		List<Information> users=ndDao.find(uir);
		if (users.size()>0) {
			return false;
		}
		return true;
	}
	@Override
	public Page<Information> showInfo(Information o,Page<Information> page,String n) {
		page.setResults(ndDao.showInfo(o, page,n));
		return page;
	}
	@Override
	public List<Information> findByTime(Information o) {
		List<Information> iuis = ndDao.findByTime(o);
		return iuis;
	}
}
